<form action='' method='post' onsubmit="return formcheck()">
	<input type="hidden" name="c" value="site" />
	<input type="hidden" name="a" value="entry" />
	<input type="hidden" name="m" value="ewei_hotel" />
	<input name="do" type="hidden" value="room_status" />
	<input name="ac" type="hidden" value="updatelot_submit" />
	<input name="days" type="hidden" value="{$days_arr}" />
	<input name="rooms" type="hidden" value="{$rooms_arr}" />
	<input name="start" type="hidden" value="{$start}" />
	<input name="end" type="hidden" value="{$end}" />
	<table class="table table-bordered tb">
		<thead>
		<tr>
			<th style="width:200px;">房型</th>
			<th style="width:120px;">房态</th>
			<th style="width:150px;">房量(空为不限)</th>
		</tr>
		</thead>
		<tbody>
		{loop $list $row}
		<tr>
			<td style="text-align: left;">{php echo cutstr($row['title'], 8)}</td>
			<td style="text-align: left;"> <label class="checkbox-inline">
				<input type="checkbox" class="status_checkbox" value="1" name="status[{$row['id']}]" checked/>有房
			</label></td>
			<td style="text-align: left;"><input type="text" name="num[{$row['id']}]" class="price_status form-control" value="{$num[$row['id']]['num']}" /></td>
		</tr>
		{/loop}
		<tr>
			<td></td>
			<td colspan='2' style="text-align: left;"><input class="btn btn-primary" id="search_button" type="submit" value="提交价格表"></td>
		</tr>
		</tbody>
	</table>
</form>

<script language="javascript">
	function formcheck(){
		var ok = true;
		$('.price_status').each(function() {
			if (!$(this).isEmpty() && !$(this).isNumber()) {
				Tip.select($(this), "请填写数字或留空", "top");
				ok = false;
				return false;
			}
		});
		return ok;
	}
</script>
